﻿using System;
using Gdk;
using Gtk;
using MonoFM.Task;

namespace MonoFM.Gui
{
    class FmEventHandler
    {
        internal static void OnKeyPressed(object o, EventKey evnt)
        {
            Console.WriteLine("Object= " + o);
            Console.WriteLine("Key="+evnt.Key);
            Console.WriteLine("Key=" + evnt.KeyValue);

//            new Task()
        }

        internal static void OnFilePanelShown(object control, EventArgs e)
        {
            new LoadFilesListTask(new ShowFilesListCommand(control as FileView));
        }

        internal static void OnCloseMainWindow(object o, DeleteEventArgs args)
        {
            Application.Quit();
            args.RetVal = true;
        }
    }
}
